<?php 
	/**
	* 
	*/
	class  Lists
	{
		
		private $list;
		private $pagesize;
		private $db;

		function __construct()
		{
			include_once('shuju.php');
			$this->db = new DB();
		}

		function listRow($page)
		{
			$pagesize = 3;
			$pagecount = $pagesize*($page-1);
			$sql = "select * from ly limit $pagecount,$pagesize";
			$this->list= $this->db->get($sql);
			return $this->list;
		}
		//获取留言总数
		function getCount()
		{
			$sql = "select * from ly";
			return $this->db->getCount($sql);

		}
	}

	
 ?>